import http from '@/libs/http'
// 获取用户信息
export const getUserInfoApi = (data) => {
	return http({
		url: `/member/by_openid`,
		data
	})
}
// oss上传
export const getOssApi = (data) => {
	return http({
		url: `/oss/token`,
		data
	})
}
// 店小二认证
export const businessMemberApi = (data) => {
	return http({
		url: `/member/business_member`,
		data,
		method: 'POST'
	})
}
// 店小二列表
export const getBusinessMemberApi = (data) => {
	return http({
		url: `/member/business_member`,
		data
	})
}
// 获取门店信息
export const getBusinessUserApi = (data) => {
	return http({
		url: `/business/get_by_user`,
		data
	})
}
// 用户登录
export const loginApi = (data) => {
	return http({
		url: `/member/save`,
		data,
		method: "POST",
	})
}

// 获取OpenId
export const getOpenIdApi = (data) => {
	return http({
		url: `/wechat/code2session`,
		data
	})
}
// 用户流水查询
export const capitalRecordApi = (data) => {
	return http({
		url: `/order/capital_record`,
		data
	})
}
// 公司流水查询
export const companyCapitalRecordApi = (data) => {
	return http({
		url: `/order/company_capital_record`,
		data
	})
}
// 获取所有会员
export const getMemberAllApi = (data) => {
	return http({
		url: `/member/all`,
		data
	})
}